package com.xbdun.web.bmp.controller.system;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.alibaba.dubbo.config.annotation.Reference;
import com.xbdun.comweb.bmp.frame.annotation.XbdunLogin;
import com.xbdun.comweb.bmp.util.UserInfoUtil;
import com.xbdun.facade.bmp.constant.DubboBmpConst;
import com.xbdun.facade.bmp.request.system.SysUserPagerRequest;
import com.xbdun.facade.bmp.result.system.QuerySysUsersPagerResult;
import com.xbdun.facade.bmp.service.system.OrgUserFacade;
import com.xbdun.facade.bmp.service.system.SysUserFacade;

import lombok.extern.slf4j.Slf4j;

//平台组件用户
@Controller
@Slf4j
@XbdunLogin
public class S109101Controller extends BaseSystemController{
	@Reference(registry=DubboBmpConst.REGISTRYS)
	SysUserFacade sysUserFacade;
	@Reference(registry=DubboBmpConst.REGISTRYS)
	OrgUserFacade orgUserFacade;
	
	//检索数据加载画面
	@RequestMapping("109101100")
	@ResponseBody
	public QuerySysUsersPagerResult search109101100(SysUserPagerRequest request){
		QuerySysUsersPagerResult result = new QuerySysUsersPagerResult();
		try{
			log.info("检索用户信息传入参数{}",request);
			result = sysUserFacade.queryUserPager(request, UserInfoUtil.getClient(getRequest()));
		}catch(Exception e){
			result.setBizException(e);
			log.error("检索用户信息异常,{}", e);
		}
		return result;
	}
	
	//用户的详情
	@RequestMapping("109101101")
	@ResponseBody
	public String getUserInfo(){
		return "";
	}
}
